<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>const常量声明</title>
</head>
<body>
    <script>
        const URL = "http://www.baidu.com";
        // const定义的变量，不能在同一个作用域内多次赋值;
        // URL = "http://www.jingdong.com";

        function run(){
            const URL = "https://www.sina.com";
            // 但在同一个作用域内，可以给数组或对象内的*元素*多次赋值;
            const ARR = [];
            ARR[0] = "563546"; 
            ARR[0] = "6666666"; 

            const DUIXIANG = {name:"xiasnn"};
            DUIXIANG.name = "XIASNN";
            DUIXIANG.name = "大美女";
        }

        run();
    </script>
</body>
</html>